package com.yx.dao;

import com.yx.entity.Person;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @Classname PersonMapper
 * @Description TODO:
 * @Date 2021/05/14 19:01
 * @Created by yx
 */
public interface PersonMapper {
    /**
     * @Author:yx
     * @return com.yx.entity.Person
     * @Date 2021/05/14 19:02
     * @param name
     * @param password
     * @Description:登录方法
     **/
    Person login(@Param("name") String name, @Param("password") String password);

    /**
     * @Author:yx
     * @return java.lang.Integer
     * @Date 2021/05/14 19:03
     * @param person
     * @Description:注册
     **/
    Integer insertPerson(Person person);

    /**
     * @Author:yx
     * @return java.util.List<com.yx.entity.Person>
     * @Date 2021/05/14 19:03
     * @param
     * @Description:查询所有
     **/
    List<Person> selectAll();

    Integer deletePerson(Integer id);

    Integer updatePerson(Person person);

    Person getPersonById(Integer id);
}
